package com.aiolos.wxdc.service.impl;

import com.aiolos.wxdc.dataobject.SellerInfo;
import com.aiolos.wxdc.repository.SellerInfoRepository;
import com.aiolos.wxdc.service.SellerService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

@Service
public class SellerServiceImpl implements SellerService {

    @Autowired
    private SellerInfoRepository repository;

    /**
     * 通过openid查找卖家信息，用于登录
     * @param openid
     * @return
     */
    @Override
    public SellerInfo findSellerInfoByOpenid(String openid) {
        return repository.findByOpenid(openid);
    }
}
